package org.dromara.hm.domain.bo;

import org.dromara.hm.domain.HmSaleOrderGift;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

import java.math.BigDecimal;

/**
 * 订单赠品明细业务对象 hm_sale_order_gift
 *
 * @author Hzy
 * @date 2025-03-17
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = HmSaleOrderGift.class, reverseConvertGenerate = false)
public class HmSaleOrderGiftBo extends BaseEntity {

    /**
     * 赠品记录ID
     */
    @NotNull(message = "赠品记录ID不能为空", groups = { EditGroup.class })
    private Long giftId;

    /**
     * 关联销售订单ID
     */
    @NotNull(message = "关联销售订单ID不能为空", groups = { AddGroup.class })
    private Long saleId;

    /**
     * 赠品商品ID
     */
    @NotNull(message = "赠品商品ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private String giftProductId;

    /**
     * 赠品数量
     */
    @NotNull(message = "赠品数量不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal giftNum;

    /**
     * 已提货数量
     */
    private BigDecimal giftUsedNum;

    /**
     * 提货状态(0-未提/1-部分提/2-已提完)
     */
    private Integer giftStatus;

    /**
     * 状态
     */
    private String status;

    /**
     * 已退赠品数量
     */
    private Integer giftRefundableNum;

    /**
     * 从已提货退货数量
     */
    private Integer pickedQty;
    /**
     * 从未提货退货数量
     */
    private Integer unpickedQty;


}
